<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        // 1.冒泡排序
        var arr = [1, 5, 49, 8, 45, 9, 2, 8, 4, 8]
        console.log(arr)
        for (var i = 0; i < arr.length; i++) {
            for (var j = 0; j < arr.length - i; j++) {
                if (arr[j] > arr[j + 1]) {
                    var c = arr[j]
                    arr[j] = arr[j + 1]
                    arr[j + 1] = c
                }
            }
        }
        console.log(arr)

        var stringArray = ["This", "is", "Baidu", "Campus"]
        console.log(stringArray.join(""))

    </script>

</body>

</html>